package t1

object Matrix_Numeric {
  
  class Matrix[N:Numeric]( val matrix:IndexedSeq[IndexedSeq[N]]){
    
      def +(o:Matrix[N])(implicit num: Numeric[N]) = {
	    if(matrix.length == o.matrix.length) for(i <- 0 until matrix.length) yield {for(j <- 0 until matrix.length) yield num.plus(matrix(0)(0), matrix(0)(0)) }
	    else matrix
	  }
    
  }
  
  	object Matrix{
	  def apply[N](i:N)(implicit num:Numeric[N]) = {
        new Matrix( for(i <- 0 until num.toInt(i)) yield {for(i <- 0 until i) yield BigInt.apply(6)} )
    }
  }//object
  	
  	class mayBeNumeric[N :Numeric](val n:N){
  	  
  	}
  	
  	def main(args: Array[String]) {
  		val v = new mayBeNumeric[BigInt](BigInt(1))
  	}

}